<template>
  <h1>{{ name }}</h1>
  <h1>{{ job.salay }}</h1>
  <el-button @click="clickFun">点击</el-button>
</template>

<script>
  import {
    ref,
    reactive
  } from 'vue'
  export default ({
    name: 'ref',
    setup() {
      let name = ref('周')

      let job = reactive({
        salay: 200
      })

      function clickFun() {
        name.value = '亮'
        job.salay = 300
      }

      return {
        name,
        job,
        clickFun
      }
    }
  })
</script>